from django.contrib import admin
from django.conf import settings
from django.urls import include, path
from django.conf.urls.static import static


from drf_spectacular.views import SpectacularJSONAPIView, SpectacularRedocView, SpectacularSwaggerView


admin.site.site_header = '配置大师'
admin.site.site_title = "配置大师管理系统"



urlpatterns = [

    path('swagger/json/', SpectacularJSONAPIView.as_view(), name='schema'),
    path('swagger/ui/', SpectacularSwaggerView.as_view(url_name='schema'), name='swagger-ui'),
    path('swagger/redoc/', SpectacularRedocView.as_view(url_name='schema'), name='redoc'),
    
    path('admin/', admin.site.urls),

    path('api/account/', include('account.urls')),

    path('api/diy/', include('diy.urls')),

    path('api/info/', include('info.urls')),

] + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT) \
  + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
